﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using SimpleData.Data;

namespace SimpleData.ObjectModel.Design
{
	public sealed class ToEditFetchStrategy : IFetchStrategy<Schema>
	{
		#region IFetchStrategy<Schema> Members

		public IQueryable<Schema> Configure( IQueryable<Schema> query )
		{
			return query
				.EagerLoad( s => s.Rules )
				.EagerLoad( s => s.Fields );
		}

		#endregion
	}
}
